﻿using System;

namespace uTrade.Core
{
    public class TradeItem
    {
        public int ID;

        /// <summary>
        /// 多空
        /// </summary>
        public TradeType TradeType;

        /// <summary>
        /// 开仓时间
        /// </summary>
        public DateTime OpenDate;

        /// <summary>
        /// 开仓价格
        /// </summary>
        public double OpenPrice;

        /// <summary>
        /// 平仓时间
        /// </summary>
        public DateTime CloseDate;

        /// <summary>
        /// 平仓价格
        /// </summary>
        public double ClosePrice;

        /// <summary>
        /// 手数
        /// </summary>
        public int Lots;

        /// <summary>
        /// 手续费
        /// </summary>
        public double Fee;

        /// <summary>
        /// 净利
        /// </summary>
        public double NetProfit;

        /// <summary>
        /// 净利合计
        /// </summary>
        public double TotalNetProfit;

        /// <summary>
        /// 收益率
        /// </summary>
        public double ReturenRate;
    }

    public enum TradeType
    {
        Long,   //多仓
        Short   //空仓
    }
}